<html>
<head>
	<script type="text/javascript" src="jquery-1.8.3.js"></script>
	<script>
		$(document).ready(function(){
			$("#random_data").click(function(){
				var randomData = [];
				var mapData = {};
				
				var range = parseInt($("#input_random_range").val());
				var size = parseInt($("#input_random_size").val());
				var randomStr = "";
				
				for(var i=0;i<size;i++){
					var data = Math.floor(Math.random()*range);
					if(!(mapData[""+data])){
						randomData.push(data);
						mapData[""+data] = true;
					}
				}
				
				$("#input_random_data").val(randomData.join(";"));
			});
		});
	</script>
</head>

<body>
	range:<input id="input_random_range" type="text" style="width:50px;" value="30" />
	times:<input id="input_random_size" type="text" style="width:50px;" value="1000" />
	random data:<input id="input_random_data" type="text" style="width:1000px;" />
	
	<input id="random_data" type="button" value="random_data">
</body>


</html>